# Hero Teammates

> `GET /api/academy/heroes/{hero_identifier}/teammates`: Academy endpoint of the Rone Arena API.

Retrieve teammate information for a specific hero. Supports query parameters for rank, pagination, and localization.

Path parameters:
- **hero_identifier**: Hero identifier as numeric hero ID or hero name. Accepts values like `30`, `Yi Sun-shin`, or `yisunshin`.

Query parameters:
- **rank**: Rank filter. Allowed values: `all`, `epic`, `legend`, `mythic`, `honor`, `glory`.
- **size**: Number of items per page (minimum: 1).
- **index**: Page index (starting from 1).
- **lang**: Language code for localized content (default: `en`).

The response includes hero teammate data:
- **records**: Array of hero entries, each containing:
    - **_id**: Unique record identifier.
    - **_createdAt**: Creation timestamp.
    - **_updatedAt**: Last update timestamp.
    - **data**:
        - **main_heroid**: Target hero ID.
        - **main_hero_ban_rate**: Ban rate of the target hero.
        - **main_hero_pick_rate**: Pick rate of the target hero.
        - **main_hero_win_rate**: Win rate of the target hero.
        - **sub_hero**: Array of teammate heroes, each containing:
            - **heroid**: Teammate hero ID.
            - **hero_win_rate**: Win rate of the teammate hero.
            - **increase_win_rate**: Impact value showing how much this hero improves or reduces win rate when paired with the target.

This endpoint is useful for:
- Analyzing which heroes synergize well with the target hero.
- Understanding team composition dynamics.
- Guiding players in drafting strategies.

## Request

`GET https://arena.rone.dev/api/academy/heroes/{hero_identifier}/teammates`

### Parameters

| Name | In | Type | Required | Default | Description |
| --- | --- | --- | --- | --- | --- |
| `hero_identifier` | path | string | yes |  | Hero identifier as numeric hero ID or hero name. Accepts values like `30`, `Yi Sun-shin`, or `yisunshin`. Name matching ignores spaces/symbols and is case-insensitive (e.g., `Luo Yi` to `luoyi`). |
| `rank` | query | string | no | `all` | Rank filter for hero statistics. One of: `all`, `epic`, `legend`, `mythic`, `honor`, `glory`. |
| `size` | query | integer | no | `20` | Number of items per page. Range: 1... |
| `index` | query | integer | no | `1` | Page index for pagination. Range: 1... |
| `lang` | query | string | no | `en` | Language code for localized content. One of: `en`, `id`, `ru`, `es`, `pt`, `tr`, `ar`, `de`, `fr`, `it`, `ja`, `ko`, `th`, `vi`, `zh-CN`, `zh-TW`, `km`. |

### Example

```bash
curl -X GET 'https://arena.rone.dev/api/academy/heroes/{hero_identifier}/teammates'
```

## Example response

```json
{
  "code": 0,
  "message": "OK",
  "data": {
    "records": [
      {
        "_createdAt": 1774899901719,
        "_id": "69cad2be54ae2bda46ed3ce7",
        "_updatedAt": 1774899901719,
        "data": {
          "big_rank": "9",
          "camp_type": "1",
          "main_hero_ban_rate": 0.08109399676322937,
          "main_hero_pick_rate": 0.010181000456213951,
          "main_hero_win_rate": 0.4657759964466095,
          "main_heroid": 17,
          "sub_hero": [
            {
              "hero_win_rate": 0.442802,
              "heroid": 69,
              "increase_win_rate": -0.114625
            }
          ]
        },
        "id": 1755924,
        "sourceId": 2777391
      }
    ],
    "total": 1
  }
}
```

## Links

- Try it in the playground: https://arena.rone.dev/web/academy/heroes/{hero_identifier}/teammates
- Academy endpoints: https://arena.rone.dev/web/academy.md
- OpenAPI schema: https://arena.rone.dev/api/openapi.json
